<?php
apf_require_class("Bll_BLL");

class Bll_Attendance_EmailLog extends BLL{

    public function insert($data){
        $this->get_email_dao()->insert($data);
    }
    public function check_has($hash){
        $where = array('hash_str'=>$hash);
        $data = $this->get_email_dao()->find($where,'',0);
        return $data;
    }
    public function delete($hash_str){
        if(empty($hash_str)){
            return false;
        }
        $where = array(
            'hash_str'=>$hash_str
        );
        $data = $this->get_email_dao()->remove($where);
    }
    public function get_list(){
         $email_list = $this->get_email_dao()->find(array(),'',0);
         return $email_list;
    }

    private function get_email_dao() {
        return $this->get_dao('DAO_Attendance_EmailLog');
    }
}